package com.example.mrwang.commadapter;

import android.content.Context;
import android.widget.TextView;

import com.common.adapter.util.CommonAdapter;
import com.common.adapter.util.CommonHolderView;

import java.util.List;

/**
 * Created by MrWang on 2016/7/5.
 * holder设置item值 可进一步做优化
 */
public class MyAdapterWithCommonViewHolder extends CommonAdapter<Family> {

    public MyAdapterWithCommonViewHolder(Context ctx, List<Family> list) {
        super(ctx, list, R.layout.item);
    }

    @Override
    protected void convertView(CommonHolderView holder, Family family, int position) {
        TextView tv = holder.getView(R.id.tv_ce);
        tv.setText(family.addr + " " + position);
    }

}
